﻿using System;
using System.Collections.Generic;
using System.Text;

namespace SanctusSoftware.Music.Lyrics.Extraction
{
    public class HymnSiteExtractor : WebSongLyricsExtractor
    {
    
        protected override string GetRawLyrics(string pageText)
        {
            return GetTextBetweenTags(pageText, "pre", true);
        }

        protected override string GetSongTitle(string pageText)
        {
            return GetTextBetweenTags(pageText, "title", true);
            //return Regex.Match(pageText, "[<]title[>](?<Title>.*)[<]/title[>]").Groups["Title"].Value;
        }

        protected override string[] GetVerses(string rawLyrics)
        {
            return rawLyrics.Split(new string[] { System.Environment.NewLine + System.Environment.NewLine }, StringSplitOptions.RemoveEmptyEntries);
        }

    }

}
